﻿using System;
using System.Collections.Generic;
using System.Text;

namespace MKAdminCore.DTO.Web.Common
{
    public class AppSettingsJsonInfo
    {
        public static ConnectionStringsInfo ConnectionStrings { get; set; }
        public static RedisDbConfig RedisConfig { get; set; }
        public static List<UploadFileInfo> UploadFileList { get; set; }
        public static EmailConfigInfo EmailInfo { get; set; }
    }

    public class ConnectionStringsInfo
    {
        public string ReadConnStr { get; set; }
    }

    public class RedisDbConfig
    {
        /// <summary>
        /// redis连接字符串
        /// </summary>
        public string HostConnection { get; set; }
        /// <summary>
        /// redis保存数据库编号
        /// </summary>
        public int DataBaseIndex { get; set; } = 1;
    }

    public class UploadFileInfo
    {
        public string Key { get; set; }
        public int FileSize { get; set; }
        public string FileTypeLimit { get; set; }
        public string SavePath { get; set; }
        public string SaveUrl { get; set; }
    }

    public class EmailConfigInfo
    {
        public bool Enabled { get; set; }
        public string Host { get; set; }
        public int Port { get; set; }
        public string UserName { get; set; }
        public string UserAddress { get; set; }
        public string Password { get; set; }
    }
}
